APCD

Section: Maintenance Commands (8)
Updated: APCD 0.5b - 8.11.1995
Index Return to Main Contents
 

NAME

apcd - daemon for APC SmartUPS support  

SYNOPSIS

/usr/sbin/apcd

 

DESCRIPTION

apcd can be used for controlling the APC SmartUPS. After the power failure, apcd will inform the users about the power failure once per minute. When the power is restored during user defined timeout, apcd will inform users about this fact. If power is not restored, the system shutdown will follow when the timeout expires. The whole shutdown is made inside the apcd , so no changes in the inittab are necessary. There is no communication between apcd and init(1) process.

apcd daemon also supports the networking mode. In this mode, one machine is configured as a master, with UPS attached to the serial port. Other machines (max. 10) are configured as a slaves. Master has a network connection with slaves and send them informations about timeouts, power restore etc. The master machine is also logging the UPS status informations to the text file.

The apcd must be setuid root !!

 

CONFIGURATION

Firstly, you will need the cable between APC Smart UPS and PC computer running Linux. You can use either the special cable which is enclosed with the PowerChute (TM) software or you can make your own cable connected as follows:

       PC (9 pin)      APC (9 pin)

       2 RxD           2

       3 TxD           1

       5 GND           9

Further, it is necessary to write configuration info to the file /etc/apcd.conf

This file is a plain ASCII file and you can use your favorite editor for configuration. For simple configuration, see enclosed sample file.

Configuration commands in /etc/apcd.conf are:

- for Master machine. Please specify which device is used for UPS communication. The default is /dev/ups.

- for Master machine. This is the timeout between power failure and system shutdown. The default is 10 minutes for the master and 9 minutes for slaves. The timeout for slaves is always one minute less than master timeout.

- for Master machine. The name of the file for logging of UPS statistics.

- for Master machine. The name of the slave machine attached to the master. There can be max. 10 slaves attached to one master.

- for Slave machine. The name of the master which is authorised to send commands to this slave

 

DIAGNOSTICS

Error and information messages are logged to the syslog daemon.

 

FILES

/etc/apcd.conf - configuration file
/var/adm/upsstat.log - the UPS status is logged in this file. The file name can be configured in /etc/apcd.conf

upsstat.log - FILE FORMAT

upsstat.log is a simple ascii file with several floating point numbers on one line. The format of the line is:

BatteryLoad LineMin LineMax UPSLoad LineFreq LineVoltage OutputVoltage UPSTemp BattVoltage

 

AUTHOR

Pavel Korensky (pavelk@dator3.anet.cz)  

BUGS AND LIMITATIONS

There are some known problems and limitations.

There can be a problem with the newest types of APC Smart UPS

Network disconnection/reconnection of the slaves is not supported.

UPS selftest, lights test etc. are not yet implemented

Some bugs, I am sure :-)


 

Index

NAME
SYNOPSIS
DESCRIPTION
CONFIGURATION
DIAGNOSTICS
FILES
AUTHOR
BUGS AND LIMITATIONS

This document was created by man2html, using the manual pages.
Time: 22:26:01 GMT, January 16, 2023